package org.example.demo03;

import java.io.FileOutputStream;
import java.io.IOException;

public class Test {
    public static void main(String[] args) throws IOException {
        //.使用字节流 读取字符串"你好,B班"的内容并写入到文件 (文件目录：C:/out01/01.txt)
        FileOutputStream os = new FileOutputStream("C:/out01/01.txt");
        String str = "你好，B班";
        byte[] bytes = str.getBytes();
        os.write(bytes);
        os.close();


    }
}
